package test.movies;

import org.openqa.selenium.WebDriver;
import org.openqa.selenium.support.ui.WebDriverWait;
import org.apache.log4j.Logger;

public abstract class PageMovies {

	    // WebDriver variables
	    protected WebDriver driver;
	    protected WebDriverWait wait;

	    // Logger variable
	    private static final org.apache.log4j.Logger LOGGER = org.apache.log4j.Logger.getLogger(PageMovies.class);

	    public PageMovies(){}

	    /**
	     * Constructor of the BasePageMovies class
	     * @param driver - configured driver
	     */
	    public PageMovies(WebDriver driver) {
	        this.driver = driver;
	        wait = new WebDriverWait(driver, 30);
	    }
	    
	    /**
	     * Method will open Login page
	     */
	    public void openMoviesServer(String moviesServerUrl) {
	        LOGGER.info("Opening Movies url");	    	
	        driver.get(moviesServerUrl);
	    }

}
